//----------------------------------------------------------------------------
// Header definitions that are shared by the server and the client
//----------------------------------------------------------------------------
#ifndef __PUBLIC_H__
#define __PUBLIC_H__
//----------------------------------------------------------------------------
// Character number
enum ClassNumber
{
    CLASS_WIZARD,
    CLASS_KNIGHT,
    CLASS_ELF,
    CLASS_MAGUMSA,
    CLASS_DARKLORD,
    CLASS_SUMMONER,
    CLASS_MONK
};

#define MAX_MAGIC					150	// Magic number of users per
#define MAX_TOTALMAGIC				100	// Magic the maximum number

//----------------------------------------------------------------------------
// Resistance number
#define RESISTANCE_COLD				0
#define RESISTANCE_POISON			1
#define RESISTANCE_THUNDER			2
#define RESISTANCE_FIRE				3

//#define MAX_RESISTANCE				4

#define MAX_SKILL					256

//----------------------------------------------------------------------------
// Number of character behavior
enum CHARACTER_AUTO_RECUPERATION_TIME
{
    CART_10_SEC = 0x2710,
    CART_15_SEC = 0x3a98,
    CART_25_SEC = 0x61a8,
};

enum HP_MP_AG_VALUE_PER_TIME
{
    VPT_HP_MP_AG_1_PER_1_SEC = 0x1,
    VPT_HP_MP_AG_5_PER_1_SEC = 0x5,
    VPT_HP_MP_AG_10_PER_1_SEC = 0xa,
};

enum eSkillType
{
    AT_SKILL_POISON = 0x1,
    AT_SKILL_METEO = 0x2,
    AT_SKILL_THUNDER = 0x3,
    AT_SKILL_FIREBALL = 0x4,
    AT_SKILL_FLAME = 0x5,
    AT_SKILL_TELEPORT = 0x6,
    AT_SKILL_SLOW = 0x7,
    AT_SKILL_STORM = 0x8,
    AT_SKILL_EVIL = 0x9,
    AT_SKILL_HELL = 0xa,
    AT_SKILL_POWERWAVE = 0xb,
    AT_SKILL_FLASH = 0xc,
    AT_SKILL_BLAST = 0xd,
    AT_SKILL_INFERNO = 0xe,
    AT_SKILL_TARGET_TELEPORT = 0xf,
    AT_SKILL_MAGICDEFENSE = 0x10,
    AT_SKILL_ENERGYBALL = 0x11,
    AT_SKILL_BLOCKING = 0x12,
    AT_SKILL_SWORD1 = 0x13,
    AT_SKILL_SWORD2 = 0x14,
    AT_SKILL_SWORD3 = 0x15,
    AT_SKILL_SWORD4 = 0x16,
    AT_SKILL_SWORD5 = 0x17,
    AT_SKILL_CROSSBOW = 0x18,
    AT_SKILL_BOW = 0x19,
    AT_SKILL_HEALING = 0x1a,
    AT_SKILL_DEFENSE = 0x1b,
    AT_SKILL_ATTACK = 0x1c,
    AT_SKILL_CALLMON1 = 0x1e,
    AT_SKILL_CALLMON2 = 0x1f,
    AT_SKILL_CALLMON3 = 0x20,
    AT_SKILL_CALLMON4 = 0x21,
    AT_SKILL_CALLMON5 = 0x22,
    AT_SKILL_CALLMON6 = 0x23,
    AT_SKILL_CALLMON7 = 0x24,
    AT_SKILL_WHEEL = 0x29,
    AT_SKILL_BLOWOFFURY = 0x2a,
    AT_SKILL_STRIKE = 0x2b,
    AT_SKILL_KNIGHTSPEAR = 0x2f,
    AT_SKILL_KNIGHTADDLIFE = 0x30,
    AT_SKILL_KNIGHTDINORANT = 0x31,
    AT_SKILL_ELFHARDEN = 0x33,
    AT_SKILL_PENETRATION = 0x34,
    AT_SKILL_DEFENSEDOWN = 0x37,
    AT_SKILL_SWORD6 = 0x38,
    AT_SKILL_5CROSSBOW = 0x36,
    AT_SKILL_EXPPOISON = 0x26,
    AT_SKILL_EXPICE = 0x27,
    AT_SKILL_EXPHELL = 0x28,
    AT_SKILL_EXPHELL_START = 0x3a,
    AT_SKILL_IMPROVE_AG_REFILL = 0x35,
    AT_SKILL_DEVILFIRE = 0x32,
    AT_SKILL_COMBO = 0x3b,
    AT_SKILL_SPEAR = 0x3c,
    AT_SKILL_FIREBURST = 0x3d,
    AT_SKILL_DARKHORSE_ATTACK = 0x3e,
    AT_SKILL_RECALL_PARTY = 0x3f,
    AT_SKILL_ADD_CRITICALDAMAGE = 0x40,
    AT_SKILL_ELECTRICSPARK = 0x41,
    AT_SKILL_LONGSPEAR = 0x42,
    AT_SKILL_RUSH = 0x2c,
    AT_SKILL_JAVALIN = 0x2d,
    AT_SKILL_DEEPIMPACT = 0x2e,
    AT_SKILL_ONE_FLASH = 0x39,
    AT_SKILL_DEATH_CANNON = 0x49,
    AT_SKILL_SPACE_SPLIT = 0x4a,
    AT_SKILL_BRAND_OF_SKILL = 0x4b,
    AT_SKILL_STUN = 0x43,
    AT_SKILL_REMOVAL_STUN = 0x44,
    AT_SKILL_ADD_MANA = 0x45,
    AT_SKILL_INVISIBLE = 0x46,
    AT_SKILL_REMOVAL_INVISIBLE = 0x47,
    AT_SKILL_REMOVAL_MAGIC = 0x48,
    AT_SKILL_FENRIR_ATTACK = 0x4c,
    AT_SKILL_SUMMON = 0xc8,
    AT_SKILL_IMMUNE_TO_MAGIC = 0xc9,
    AT_SKILL_IMMUNE_TO_HARM = 0xca,
};

enum eOptionType
{
    AT_IMPROVE_DAMAGE = 0x50,
    AT_IMPROVE_MAGIC = 0x51,
    AT_IMPROVE_BLOCKING = 0x52,
    AT_IMPROVE_DEFENSE = 0x53,
    AT_LUCK = 0x54,
    AT_LIFE_REGENERATION = 0x55,
    AT_IMPROVE_LIFE = 0x56,
    AT_IMPROVE_MANA = 0x57,
    AT_DECREASE_DAMAGE = 0x58,
    AT_REFLECTION_DAMAGE = 0x59,
    AT_IMPROVE_BLOCKING_PERCENT = 0x5a,
    AT_IMPROVE_GAIN_GOLD = 0x5b,
    AT_EXCELLENT_DAMAGE = 0x5c,
    AT_IMPROVE_DAMAGE_LEVEL = 0x5d,
    AT_IMPROVE_DAMAGE_PERCENT = 0x5e,
    AT_IMPROVE_MAGIC_LEVEL = 0x5f,
    AT_IMPROVE_MAGIC_PERCENT = 0x60,
    AT_IMPROVE_ATTACK_SPEED = 0x61,
    AT_IMPROVE_GAIN_LIFE = 0x62,
    AT_IMPROVE_GAIN_MANA = 0x63,
    AT_PLUS_WING_MAXLIFE = 0x64,
    AT_PLUS_WING_MAXMANA = 0x65,
    AT_PLUS_ONE_PERCENT_DAMAGE = 0x66,
    AT_IMPROVE_AG_MAX = 0x67,
    AT_DAMAGE_ABSORB = 0x68,
    AT_PLUS_WING_ADD_LEADERSHIP = 0x69,
    AT_PLUS_FENRIR_INCREASE_LAST_DAMAGE = 0x6a,
    AT_PLUS_FENRIR_DECREASE_LAST_DAMAGE = 0x6b,
    AT_ATTACK1 = 0x78,
    AT_ATTACK2 = 0x79,
    AT_STAND1 = 0x7a,
    AT_STAND2 = 0x7b,
    AT_MOVE1 = 0x7c,
    AT_MOVE2 = 0x7d,
    AT_DAMAGE1 = 0x7e,
    AT_DIE1 = 0x7f,
    AT_SIT1 = 0x80,
    AT_POSE1 = 0x81,
    AT_HEALING1 = 0x82,
    AT_GREETING1 = 0x83,
    AT_GOODBYE1 = 0x84,
    AT_CLAP1 = 0x85,
    AT_GESTURE1 = 0x86,
    AT_DIRECTION1 = 0x87,
    AT_UNKNOWN1 = 0x88,
    AT_CRY1 = 0x89,
    AT_CHEER1 = 0x8a,
    AT_AWKWARD1 = 0x8b,
    AT_SEE1 = 0x8c,
    AT_WIN1 = 0x8d,
    AT_SMILE1 = 0x8e,
    AT_SLEEP1 = 0x8f,
    AT_COLD1 = 0x90,
    AT_AGAIN1 = 0x91,
    AT_RESPECT1 = 0x92,
    AT_SALUTE1 = 0x93,
    AT_RUSH1 = 0x94,
    AT_SET_RING_OPTION_ADD_SKILLDAMAGE = 0x95,
    AT_SET_OPTION_IMPROVE_STRENGTH = 0xa0,
    AT_SET_OPTION_IMPROVE_DEXTERITY = 0xa1,
    AT_SET_OPTION_IMPROVE_ENERGY = 0xa2,
    AT_SET_OPTION_IMPROVE_VITALITY = 0xa3,
    AT_SET_OPTION_IMPROVE_LEADERSHIP = 0xa4,
    AT_SET_OPTION_IMPROVE_MINATTACKDAMAGE = 0xa5,
    AT_SET_OPTION_IMPROVE_MAXATTACKDAMAGE = 0xa6,
    AT_SET_OPTION_IMPROVE_MAGICDAMAGE = 0xa7,
    AT_SET_OPTION_IMPROVE_DAMAGE = 0xa8,
    AT_SET_OPTION_IMPROVE_ATTACKRATE = 0xa9,
    AT_SET_OPTION_IMPROVE_DEFENCE = 0xaa,
    AT_SET_OPTION_IMPROVE_MAXLIFE = 0xab,
    AT_SET_OPTION_IMPROVE_MAXMANA = 0xac,
    AT_SET_OPTION_IMPROVE_MAXAG = 0xad,
    AT_SET_OPTION_IMPROVE_AG_VALUE = 0xae,
    AT_SET_OPTION_IMPROVE_CRITICALDAMAGE_SUCCESS = 0xaf,
    AT_SET_OPTION_IMPROVE_CRITICALDAMAGE = 0xb0,
    AT_SET_OPTION_IMPROVE_EX_DAMAGE_SUCCESS = 0xb1,
    AT_SET_OPTION_IMPROVE_EX_DAMAGE = 0xb2,
    AT_SET_OPTION_IMPROVE_SKILLDAMAGE = 0xb3,
    AT_SET_OPTION_DOUBLE_DAMAGE = 0xb4,
    AT_SET_OPTION_DEFENCE_IGNORE = 0xb5,
    AT_SET_OPTION_IMPROVE_SHIELD_DEFENCE = 0xb6,
    AT_SET_OPTION_TWO_HAND_SWORD_IMPROVE_DAMAGE = 0xb7,
    AT_SET_OPTION_IMPROVE_ATTACKDAMAGE_WITH_STR = 0xb8,
    AT_SET_OPTION_IMPROVE_ATTACKDAMAGE_WITH_DEX = 0xb9,
    AT_SET_OPTION_IMPROVE_DEFENCE_WITH_DEX = 0xba,
    AT_SET_OPTION_IMPROVE_DEFENCE_WITH_VIT = 0xbb,
    AT_SET_OPTION_IMPROVE_MAGICDAMAGE_WITH_ENERGY = 0xbc,
    AT_SET_OPTION_ICE_MASTERY = 0xbd,
    AT_SET_OPTION_POSION_MASTERY = 0xbe,
    AT_SET_OPTION_THUNDER_MASTERY = 0xbf,
    AT_SET_OPTION_FIRE_MASTERY = 0xc0,
    AT_SET_OPTION_EARTH_MASTERY = 0xc1,
    AT_SET_OPTION_WIND_MASTERY = 0xc2,
    AT_SET_OPTION_WATER_MASTERY = 0xc3,
    AT_SET_IMPROVE_STRENGTH = 0xc4,
    AT_SET_IMPROVE_DEXTERITY = 0xc5,
    AT_SET_IMPROVE_ENERGY = 0xc6,
    AT_SET_IMPROVE_VITALITY = 0xc7,
};

enum DB_CLASS_TYPE
{
    DB_CLASS_TYPE_WIZARD = 0x0,
    DB_CLASS_TYPE_KNIGHT = 0x10,
    DB_CLASS_TYPE_ELF = 0x20,
    DB_CLASS_TYPE_MAGUMSA = 0x30,
    DB_CLASS_TYPE_DARKLORD = 0x40,
    DB_CLASS_TYPE_SUMMONER = 0x50,
    DB_CLASS_TYPE_MONK = 0x60,
};

enum AMS
{
    AM_NONE = 0x0,
    AM_STANDBY = 0x0,
    AM_ACTIVE = 0x1,
};

//----------------------------------------------------------------------------

#endif
